﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace AFCEPF.BankApplication.BLL
{
    public abstract class CommandBase<T> : ICommand<T>
    {
        protected T _target;
        
        /// <summary>
        /// Initializes a new instance of the <see cref="CommandBase&lt;T&gt;"/> class.
        /// </summary>
        /// <param name="target">The target.</param>
        protected CommandBase(T target)
        {
            _target = target;
        }

        /// <summary>
        /// Executes the specified command on the target.
        /// </summary>
        /// <param name="target">The target.</param>
        public abstract void Execute(T target);
        /// <summary>
        /// Unexecutes the specified command on the target.
        /// </summary>
        /// <param name="target">The target.</param>
        public abstract void UnExecute(T target);
    }
}
